#include <iostream>
#include <memory>
#include "ThreadPool.hpp"
#include <ctime>
#include <cstdlib>

using namespace std;

int main()
{
    yui::ThreadPool<int>::getInstance()->init();
    yui::ThreadPool<int>::getInstance()->start();
    srand((size_t)time(nullptr));
    while(true)
    {
        sleep(1);
        int tmp = rand()%100;
        yui::ThreadPool<int>::getInstance()->pushTask(tmp);
    }
    return 0;
}